import { createStore } from "vuex";
export default createStore({
  state: {
    showTabBar: true,
    userInfo:{token:''},
    listData:0,
    num:0
  },
  mutations: {
    changeshowTabBar(state,boolean){
      state.showTabBar = boolean;
    },
    setUserInfo(state,data){
      state.userInfo = data;
    },
    setData(state,value){
        state.listData=value
    },
    addNum(state){
      state.num=state.num+10
    }
  },
  actions: {
    setData(context,value){
      context.commit('setData',value)
    },
  },
  modules: {}
});
